// ****************************************************************************
//
// Logic 2: First room   Outside Voodoo Girl's Hut
//
// ****************************************************************************

#include "defines.txt"

if (new_room) {
  load.pic(room_no);
  draw.pic(room_no);
  discard.pic(room_no);
  set.horizon(27);

  // The next 6 lines need only be in the first room of the game
  if ((prev_room_no == 1 ||    // just come from intro screen
      prev_room_no == 0)) {    // or just started game
    position(ego,62,109);
    status.line.on();
    accept.input();
  }

// Check what room the player came from and position them on the
// screen accordingly here, e.g:
if (prev_room_no == 5) {
   position(ego,62,109);
 }

  draw(ego);
  show.pic();
}

if (said("look")) {
  print("Outside Voodoo Girl's hut is a clearing.  The forest wraps around.  A moss covered rock sits in the sunlight.");
}

if (said("look","hut")) {
  print("You remember when you built this hut...");
  print("That is to say you remember when you turned a carpenter into a zombie and forced him to build this hut.");
  }

if (said("look","rock")) {
   print("Some sort of moss is growing on the shady, damp side of this rock.");
   }

if (said("look","forest")) {
   print("Your humble home is surrounded by gorgeous mahogany trees.");
   }

if (said("look","moss")) {
  if (!has("sleep moss")){
     print("This is a rare form of moss called sleep moss.");
     }
  else {
     show.obj(50); //sleep moss
     }
  }

if (said("take","moss") && obj.in.box(ego, 80, 50, 130, 75)) {
    if (sleep_moss<3){
       print("You take the sleep moss and store it in your inhumanly baggy raver pants.");
       sleep_moss+=1; //sleep moss
       }
    else {
       print("You already have some.  Let the poor moss recuperate from your savage harvest.");
       }
   }

if (ego_edge_code == horizon_edge) {  // ego touching horizon
  new.room(3);
}

if (ego_touching_signal_line) {    // ego in Voodoo Girl's door
  new.room(5);
}


return();